// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import FastClick from 'fastclick'
// import VueRouter from 'vue-router'
import App from './App'
// import Home from './components/HelloFromVux'
import router from './router'
import './fit.less'
import './common.less'
import { XHeader, Tab, TabItem, XButton, Group, Cell, Swiper, XSwitch, SwiperItem, XInput, XTable, CellBox, Toast, AlertPlugin, ToastPlugin, DatetimePlugin } from 'vux'

Vue.component('x-header', XHeader)
Vue.component('tab', Tab)
Vue.component('tab-item', TabItem)
Vue.component('x-button', XButton)
Vue.component('group', Group)
Vue.component('cell', Cell)
Vue.component('swiper', Swiper)
Vue.component('swiper-item', SwiperItem)
Vue.component('x-switch', XSwitch)
Vue.component('x-input', XInput)
Vue.component('x-table', XTable)
Vue.component('cell-box', CellBox)
Vue.component('toast', Toast )

Vue.use(DatetimePlugin)
Vue.use(AlertPlugin)
Vue.use(ToastPlugin, { position: 'middle' })


FastClick.attach(document.body)

Vue.config.productionTip = false
Vue.prototype.globalData = {
  cid: ''
}

/* eslint-disable no-new */
new Vue({
  router,
  render: h => h(App),
}).$mount('#app-box')
